#include "kd_tree.hpp"

Kd_Node::Kd_Node(const double _data,unsigned short _dimension) : left(NULL), right(NULL), data(_data), dimension(_dimension) , photon(NULL) { }

void Kd_Node::add_left(Kd_Node* _left) { left = _left; }

void Kd_Node::add_right(Kd_Node* _right) { right = _right; }

void Kd_Node::add_photon(Photon* _photon) { photon = _photon; }

void Kd_Node::pre_order(void) {
	//this->photon->get_position().mostrar();
	
	if(this->left != NULL) this->left->pre_order();
	cout << "." << endl;
	if(this->right != NULL) this->right->pre_order();
}

Kd_Tree::Kd_Tree(void) { }
